Skip to main content
This forum is closed to new posts and responses. Individual names altered for privacy purposes. The information contained in this website is provided for informational purposes only and should not be construed as a forum for customer support requests. Any customer support requests should be directed to the official HCL customer support channels below:

HCL Software Customer Support Portal for U.S. Federal Government clients
HCL Software Customer Support Portal

HCL Notes/Domino 8.5 Forum (includes Notes Traveler)

HCL Notes/Domino 8.5 Forum (includes Notes Traveler)

Previous Next
Subject: dojo.xhrGet and response data
Feedback Type: Question
Product Area: Domino Server
Technical Area: Application Development
Platform: ALL
Release: 8.5.2
Reproducible: Not applicable

Hi,

I'm new to dojo and have set up some javascript to get values from a Notes agent.

function getData(agentName) {

//The parameters to pass to xhrGet, the url, how to handle it, and the callbacks.
var xhrArgs = {
url: DBurl+ "/" + agentName,
handleAs: "text",
load: function(response, ioArgs) {
alert("response= " +response);
retVal = response;
},
error: function(response, ioArgs) {
console.error("HTTP status code: ", ioArgs.xhr.status);
alert(response);
}

}

//Call the asynchronous xhrGet
var deferred = dojo.xhrGet(xhrArgs);


}

The function works and returns data from my agent, however. The agent has a print statement as follows:

Print "<OPTION>SELECT</OPTION>"

however, the response text reads:

"<html>
<head>
</head>
<body text="#000000">
<OPTION>SELECT</OPTION>
</body>
</html>"

Am I doing something wrong? Can I just return the bit I set in the print statement? or is this standard and I just need to strip away the extranious tags?


Feedback number WEBB8DF3XN created by ~Ned Dwoatexakol on 01/25/2011

Status: Open
Comments:

dojo.xhrGet and response data (~Ned Dwoatexako... 25.Jan.11)
. . set content type (~Evelyn Desjumi... 25.Jan.11)




Printer-friendly

Search this forum

Member Tools


RSS Feeds

 RSS feedsRSS
All forum posts RSS
All main topics RSS